package com.yulongtian.weekCompetition.month202301.week04;


/**
 * 可
 *
 * @author yulongTian
 * @create 2023-01-22 10:23
 */
public class Test03 {
    public static void main(String[] args) {
        String s = "001000";
        String target = "000100";
        System.out.println(makeStringsEqual(s, target));
    }


    public static boolean makeStringsEqual(String s, String target) {
        boolean sFlag = false;
        boolean tFlag = false;
        for (int i = 0; i < s.length(); i++) {
            if (s.charAt(i) == '1') {
                sFlag = true;
                break;
            }
        }
        for (int i = 0; i < target.length(); i++) {
            if (target.charAt(i) == '1') {
                tFlag = true;
                break;
            }
        }
        if (sFlag && tFlag || !sFlag && !tFlag) {
            return true;
        } else {
            return false;
        }
    }
}
